<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>

</body>
<script>
    var obj = {b:"b"}
    Object.defineProperty(obj,"a",{
        //writable:true, //属性可写
        //value:"xxx",//属性值
        enumerable:false,//属性是否可枚举(能否出现在对象的for in循环中)
        configurable:true,//属性是否库被重新配置(能不能重新定义 能不能删除)
        get(){return "yyy"},
        set(val){}
    })


    console.log(obj.a);
</script>
</html>